<!doctype html>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../assert_selection.js"></script>
<script>
selection_test(
  [
    '<div contenteditable>',
    '<i>^foo</i>',
    '<div contenteditable="false">bar</div>',
    '<i>baz|</i>',
    '</div>',
  ],
  'formatblock <h1>',
  [
    '<div contenteditable>',
      '<h1><i>^foo</i><br><i>baz</i></h1>',
      // TODO(crbug.com/855207): This should be
      // '|<div contenteditable="false">bar</div>'
      '<div contenteditable="false">|bar</div>',
    '</div>',
  ],
  'formatBlock with uneditable');
</script>
